package com.example.aicooking.entity.dto;

import lombok.Data;
import java.util.List;

@Data
public class ChatHistoryResponse {
    private Integer limit;
    private Boolean hasMore;
    private List<ChatMessage> data;

    @Data
    public static class ChatMessage {
        private String id;
        private String conversationId;
        private Object inputs;
        private String query;
        private String answer;
        private List<MessageFile> messageFiles;
        private Object feedback;
        private List<RetrieverResource> retrieverResources;
        private List<AgentThought> agentThoughts;
        private Long createdAt;
    }

    @Data
    public static class MessageFile {
        private String id;
        private String type;
        private String url;
        private String belongsTo;
    }

    @Data
    public static class RetrieverResource {
        private Integer position;
        private String datasetId;
        private String datasetName;
        private String documentId;
        private String documentName;
        private String segmentId;
        private Double score;
        private String content;
    }

    @Data
    public static class AgentThought {
        private String id;
        private String chainId;
        private String messageId;
        private Integer position;
        private String thought;
        private String tool;
        private String toolInput;
        private Long createdAt;
        private String observation;
        private List<String> messageFiles;
    }
}